<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <button>点击</button>
    <div></div>
    <script>
        var btn = document.querySelector('button');
        var div = document.querySelector('div');
        btn.addEventListener('click', function() {
            // 跳转到 B站 《JavaScript BOM与DOM》 的学习视频
            location.href = 'https://www.bilibili.com/video/BV1k4411w7sV?p=92&share_source=copy_web&vd_source=d60891811856d864c216f6f0994c1a66';
        })
        // 
        var time = 5;
        setInterval(function() {
            if(time == 0) {
                location.href = 'https://space.bilibili.com/437759560?spm_id_from=333.788.0.0';
            } else {
                div.innerHTML = '你将在'+ time + '秒之后跳转到本人的B站首页！！！';
                time--;
            }
            
        },1000);
    </script>
</body>
</html>